<%@ page language="java" import="java.util.*,com.pmc.dwa.common.utils.ConfigParameter" pageEncoding="utf-8"%>
<%
String sysMainName = ConfigParameter.getParamVal("sysconf.properties","sysMainName");
String sysSubName = ConfigParameter.getParamVal("sysconf.properties","sysSubName");
String sysVersion = ConfigParameter.getParamVal("sysconf.properties","sysVersion");
%>
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
  <head>
    <title><%=sysMainName%>-<%=sysSubName%> <%=sysVersion%></title>
	<%@ include file="/common/view/header.jsp"%>
    <link rel="stylesheet" type="text/css" href="<%=cp%>/common/styles/index.css">
	<script language="javascript">
	if(self!=top){
		top.location.replace(self.location)
	}
	function CheckInput(fobj){
		if(fobj.j_username.value==""){
			$.messager.alert('登录提示', '请您输入用户名！', 'info');
			fobj.j_username.focus();
			return false;
		}
		if(fobj.j_password.value==""){
			$.messager.alert('登录提示', '请您输入登录密码！', 'info');
			fobj.j_password.focus();
			return false;
		}
		return true;
	}
	function resetForm(fobj){
		fobj.reset();
	}
	function form2center(){
		var width = 1000;
		var height = 600;
		var top = (document.body.clientHeight-height)/2;
		var left = (document.body.clientWidth-width)/2;
		var odiv = $("#loginpage")[0];
		odiv.style.top = top;
		odiv.style.left = left;
		odiv.style.width = width;
		odiv.style.height = height;
	}
	window.onload =  function(){
		form2center();
		document.login_form.j_username.focus();
		if("${param.login_error}" == "1"){
			$.messager.alert('登录提示','用户名或密码输入有误，请重试。','error');
		}
	}
	window.onresize = function(){
		form2center();
	}
	</script>
  </head>
  
  <body>
  <div id="loginpage" style="position:absolute; border:1px #fff solid;">
	<table width="1000" border="0" align="center" cellpadding="0" cellspacing="0">
	  <tr>
		<td height="107" valign="top" background="common/images/login/001.png"><table width="30%" border="0" align="right" cellpadding="0" cellspacing="0">
		  <tr>
			<td height="40" align="right" style="padding-right:10px;"><span style="font-size:12px;">版权所有&copy;北京天下图数据技术有限公司</span></td>
		  </tr>
		</table></td>
	  </tr>
	</table>
	<table width="1000" border="0" align="center" cellpadding="0" cellspacing="0">
	  <tr>
		<td height="81" background="common/images/login/002.png">&nbsp;</td>
	  </tr>
	</table>
	<table width="1000" border="0" align="center" cellpadding="0" cellspacing="0">
	  <tr>
		<td height="85" background="common/images/login/003.png">&nbsp;</td>
	  </tr>
	</table>
	<table width="1000" border="0" align="center" cellpadding="0" cellspacing="0">
	  <tr>
		<td width="557"><img src="common/images/login/left01.png" width="557" height="215" /></td>
		<td><img src="common/images/login/right01.png" alt="" width="443" height="215" /></td>
	  </tr>
	</table>
	<table width="1000" border="0" align="center" cellpadding="0" cellspacing="0">
	  <tr>
		<td height="82" align="center" bgcolor="#D8E0E5"><table width="60%" border="0" cellspacing="0" cellpadding="0">
		<form name="login_form" method="post" action="<%=cp%>/j_spring_security_check" id="login_form" onSubmit="return CheckInput(this);" style="margin:0px;padding:0px;">
		  <tr>
			<td><img src="common/images/login/username.gif" width="85" height="25" /></td>
			<td style="padding-right:10px;"><input type="text" name="j_username" maxlength="20" value="" class="logininput" /></td>
			<td><img src="common/images/login/password.gif" width="85" height="25" /></td>
			<td style="padding-right:10px;"><input type="password" name="j_password" maxlength="20" value="" class="logininput" /></td>
			<td style="padding-right:10px;"><input type="image" name="btnSubmit" src="common/images/login/btnlogin.png" width="80" height="25" border="0"></td>
			<td><img name="btnReset" src="common/images/login/btncancle.png" width="80" height="25" onClick="javascript:resetForm(document.login_form);" style="cursor:pointer;" /></td>
		  </tr>
		</form>
		</table></td>
	  </tr>
	  <tr>
		<td height="30" bgcolor="#D8E0E5">&nbsp;</td>
	  </tr>
	</table>
  </div>
  </body>
</html>